package org.security

class Role {
	int priorty
	String roleName
	String remark
	
	String authority
	
	static hasMany = [resources:Resource]
	
	static mapping = {
		cache true
	}

	static constraints = {
		priorty()
		roleName()
		remark(blank:true)
		authority blank: false, unique: true
		remark(widget:'textarea',blank:true)
	}
	String toString(){
		return "${roleName}"
	}
}
